import React from 'react';
import {NavLink,Routes,Route} from "react-router-dom";
import Home from "./pages/Home";
import One from "./pages/One";
import Two from "./pages/Two";
import Three from "./pages/Three";
import "./App.css";


function App () {
    return (
        <div className='container'>
            <nav>
                <NavLink to={'/'}>首页</NavLink>
                <NavLink to={{pathname:'/one', search:'a=1&b=2'}}>one</NavLink>
                <NavLink to={'/two'}>two</NavLink>
                <NavLink to={'/three/1-2.php'}>three</NavLink>
            </nav>
            <Routes>
                <Route path={'/'} element={<Home></Home>}></Route>
                <Route path={'/one'} element={<One></One>}></Route>
                <Route path={'/two'} element={<Two></Two>}></Route>
                <Route path={'/three/:a-:b.php'} element={<Three></Three>}></Route>
            </Routes>


        </div>



    )
}
export default App 